<!--{template common/header}-->

<div id="wp" class="wp">
	<div id="pt" class="bm cl">
		<!--{if empty($gid) && $announcements}-->
		<div class="y">
			<div id="an">
				<dl class="cl">
					<dt class="z xw1">{lang announcements}:&nbsp;</dt>
					<dd>
						<div id="anc"><ul id="ancl">$announcements</ul></div>
					</dd>
				</dl>
			</div>
			<script type="text/javascript">announcement();</script>
		</div>
		<!--{/if}-->
		<div class="z">
			<a href="./" class="nvhm" title="{lang homepage}">$_G[setting][bbname]</a><em>&raquo;</em><a href="forum.php">{$_G[setting][navs][2][navname]}</a>$navigation
		</div>
		<div class="z"><!--{hook/index_status_extra}--></div>
	</div>


<!--{if empty($gid)}-->
	<!--{ad/text/wp a_t}-->
<!--{/if}-->

	<style id="diy_style" type="text/css"></style>

	<div class="wp">
		<!--[diy=diy1]--><div id="diy1" class="area"></div><!--[/diy]-->
	</div>

<div id="ct" class="wp cl ct2">
	<!--[diy=diy_chart]--><div id="diy_chart" class="area"></div><!--[/diy]-->
	<div class="mn" style="width:680px !important; float:left;">
		<!--{hook/index_catlist_top}-->
		<div class="wp mtn" style="padding-bottom:0;">
			<!--{if empty($gid)}-->
			<!--[diy=diy3]--><div id="diy3" class="area"></div><!--[/diy]-->
			<!--[diy=diy1187]--><div id="diy1187" class="area"></div><!--[/diy]-->
			<!--{/if}-->
			<!--{if empty($gid) && !empty($_G['setting']['grid']['showgrid'])}-->
			<!-- index four grid -->
			<div class="n_topic_b">
				<div class="cl">
					<div class="frame-title title"><span class="titletext">{$_G['style']['n_topic_b_title']}</span></div>
					<div class="n_topic_large">
						<ul>
							<!--{eval $tttttttt = C::t('forum_thread')->fetch_all_for_guide('newthread', 0, array(), 0, 0, 0, 30, 0)}-->

							<!--{loop $tttttttt $thread}-->
								<!--{if !$thread['forumstick'] && $thread['closed'] > 1 && ($thread['isgroup'] == 1 || $thread['fid'] != $_G['fid'])}-->
									<!--{eval $thread[tid]=$thread[closed];}-->
								<!--{/if}-->
							<li>
								<dl class="cl">
									<dd class="m"><a href="home.php?mod=space&uid=$thread[authorid]"{if $_G['setting']['grid']['targetblank']} target="_blank"{/if}><!--{avatar($thread[authorid],small)}--></a></dd>
									<dt><a href="forum.php?mod=viewthread&tid=$thread[tid]&extra=$extra"{if $thread['highlight']} $thread['highlight']{/if}title="$thread[subject]"{if $_G['setting']['grid']['targetblank']} target="_blank"{/if} class="_title">$thread[subject]</a></dt>
									<dd class="author"><a href="forum.php?mod=forumdisplay&fid=$thread[fid]"{if $_G['setting']['grid']['targetblank']} target="_blank"{/if} class="forumurl">{if $forumlist[$thread[fid]][name] && $thread['isgroup'] !== 1}$forumlist[$thread[fid]][name]{else}<!--{eval $tmp_group = C::t('forum_forum')->fetch_all_name_by_fid($thread['fid']);}-->$tmp_group[$thread[fid]][name]{/if}</a><a href="home.php?mod=space&uid=$thread[authorid]"{if $_G['setting']['grid']['targetblank']} target="_blank"{/if}><em class="author">$thread[author]</em></a> <em class="dateline"><!--{eval $dateline = str_replace('"', '\'', dgmdate($thread[dateline], 'u', '9999', getglobal('setting/dateformat')));}-->$dateline</em><em class="lastposter">{$_G['style']['n_topic_b_lastposter']}</em><a href="home.php?mod=space&username=$thread[lastposter]"{if $_G['setting']['grid']['targetblank']} target="_blank"{/if}>$thread[lastposter]</a>{if $thread[replies]}<em class="replies">$thread[replies]</em>{/if}</dd>
								</dl>
							</li>
							<!--{/loop}-->
						</ul>
					</div>
				</div>
			</div>
			<!-- index four grid end -->
			<!--{/if}-->
		</div>
		<!--{if empty($gid)}-->
		<div class="title">{$_G['style']['jour_title']}</div>
		<div class="jour fl bm">
		<!--{else}-->
		<div class="gid jour fl bm">
		<!--{/if}-->
		
			<!--{if !empty($collectiondata['follows'])}-->

			<!--{eval $forumscount = count($collectiondata['follows']);}-->
			<!--{eval $forumcolumns = 4;}-->

			<!--{eval $forumcolwidth = (floor(100 / $forumcolumns) - 0.1).'%';}-->

			<div class="bm bmw {if $forumcolumns} flg{/if} cl">
				<div class="bm_h cl">
					<h2><a href="forum.php?mod=collection&op=my">{lang my_order_collection}</a></h2>
				</div>
				<div id="category_-1" class="bm_c" style="{echo $collapse['category_-1']}">
					<table cellspacing="0" cellpadding="0" class="fl_tb">
						<tr>
						<!--{eval $ctorderid = 0;}-->
						<!--{loop $collectiondata['follows'] $key $colletion}-->
							<!--{if $ctorderid && ($ctorderid % $forumcolumns == 0)}-->
								</tr>
								<!--{if $ctorderid < $forumscount}-->
									<tr class="fl_row">
								<!--{/if}-->
							<!--{/if}-->
							<td class="fl_g"{if $forumcolwidth} width="$forumcolwidth"{/if}>
								<div class="fl_icn_g">
								<a href="forum.php?mod=collection&action=view&ctid={$colletion[ctid]}" target="_blank"><img src="{IMGDIR}/forum{if $followcollections[$key]['lastvisit'] < $colletion['lastupdate']}_new{/if}.gif" alt="$colletion[name]" /></a>
								</div>
								<dl>
									<dt><a href="forum.php?mod=collection&action=view&ctid={$colletion[ctid]}">$colletion[name]</a></dt>
									<dd><em>{lang forum_threads}: <!--{echo dnumber($colletion[threadnum])}--></em>, <em>{lang collection_commentnum}: <!--{echo dnumber($colletion[commentnum])}--></em></dd>
									<dd>
									<!--{if $colletion['lastpost']}-->
										<!--{if $forumcolumns < 3}-->
											<a href="forum.php?mod=redirect&tid=$colletion[lastpost]&goto=lastpost#lastpost" class="xi2"><!--{echo cutstr($colletion[lastsubject], 30)}--></a> <cite><!--{date($colletion[lastposttime])}--> <!--{if $colletion['lastposter']}-->$colletion['lastposter']<!--{else}-->$_G[setting][anonymoustext]<!--{/if}--></cite>
										<!--{else}-->
											<a href="forum.php?mod=redirect&tid=$colletion[lastpost]&goto=lastpost#lastpost">{lang forum_lastpost}: <!--{date($colletion[lastposttime])}--></a>
										<!--{/if}-->
									<!--{else}-->
										{lang never}
									<!--{/if}-->
									</dd>
									<!--{hook/index_followcollection_extra $colletion[ctid]}-->
								</dl>
							</td>
							<!--{eval $ctorderid++;}-->

						<!--{/loop}-->
						<!--{if ($columnspad = $ctorderid % $forumcolumns) > 0}--><!--{echo str_repeat('<td class="fl_g"'.($forumcolwidth ? " width=\"$forumcolwidth\"" : '').'></td>', $forumcolumns - $columnspad);}--><!--{/if}-->
						</tr>
					</table>

				</div>
			</div>

			<!--{/if}-->
			<!--{if empty($gid) && !empty($forum_favlist)}-->
			<!--{eval $forumscount = count($forum_favlist);}-->
			<!--{eval $forumcolumns = $forumscount > 3 ? ($forumscount == 4 ? 4 : 5) : 1;}-->

			<!--{eval $forumcolwidth = (floor(100 / $forumcolumns) - 0.1).'%';}-->

			<div class="bm bmw {if $forumcolumns} flg{/if} cl">
				<div class="bm_h cl">
					<h2><a href="home.php?mod=space&do=favorite&type=forum">{lang forum_myfav}</a></h2>
				</div>
				<div id="category_0" class="bm_c" style="{echo $collapse['category_0']}">
					<!--{eval $favorderid = 0;}-->
					<!--{loop $forum_favlist $key $favorite}-->
					<!--{if $favforumlist[$favorite[id]]}-->
					<!--{eval $forum=$favforumlist[$favorite[id]];}-->
					<!--{eval $forumurl = !empty($forum['domain']) && !empty($_G['setting']['domain']['root']['forum']) ? 'http://'.$forum['domain'].'.'.$_G['setting']['domain']['root']['forum'] : 'forum.php?mod=forumdisplay&fid='.$forum['fid'];}-->
						<span>
							<a href="$forumurl" class="forumname" {if $forum[redirect]} target="_blank"{/if}{if $forum[extra][namecolor]} style="color: {$forum[extra][namecolor]};"{/if}>$forum[name]<!--{if $forum['redirect']}--> *<!--{/if}--></a> <!--{if $forum[todayposts] && !$forum['redirect']}--><em class="xw0 xi1" title="{lang forum_todayposts}">$forum[todayposts]</em><!--{/if}-->
						</span>
						<span>
							<!--{if $forum['subforums']}--><!--{eval $forum['subforums'] = str_replace(",","",$forum['subforums'])}-->$forum['subforums']<!--{/if}-->
							<!--{hook/index_forum_extra $forum[fid]}-->
						</span>
					<!--{/if}-->
					<!--{/loop}-->
					<!--{if ($columnspad = $favorderid % $forumcolumns) > 0}--><!--{echo str_repeat('<td class="fl_g"'.($forumcolwidth ? " width=\"$forumcolwidth\"" : '').'></td>', $forumcolumns - $columnspad);}--><!--{/if}-->
				</div>
			</div>
			<!--{ad/intercat/bm a_c/-1}-->
		<!--{/if}-->
		<!--{loop $catlist $key $cat}-->
			<!--{hook/index_catlist $cat[fid]}-->
			<div class="bm bmw {if $cat['forumcolumns']} flg{/if} cl">
				<div class="bm_h cl">
					<!--{eval $caturl = !empty($cat['domain']) && !empty($_G['setting']['domain']['root']['forum']) ? 'http://'.$cat['domain'].'.'.$_G['setting']['domain']['root']['forum'] : '';}-->
					<h2><a href="{if !empty($caturl)}$caturl{else}forum.php?gid=$cat[fid]{/if}" style="{if $cat[extra][namecolor]}color: {$cat[extra][namecolor]};{/if}">$cat[name]</a></h2>
				</div>
				<div id="category_$cat[fid]" class="bm_c" style="{echo $collapse['category_'.$cat[fid]]}">
					<!--{if !empty($gid)}-->
					<table cellspacing="0" cellpadding="0" class="fl_tb">
						<tr>
					<!--{/if}-->
					<!--{loop $cat[forums] $forumid}-->
					<!--{eval $forum=$forumlist[$forumid];}-->
					<!--{eval $forumurl = !empty($forum['domain']) && !empty($_G['setting']['domain']['root']['forum']) ? 'http://'.$forum['domain'].'.'.$_G['setting']['domain']['root']['forum'] : 'forum.php?mod=forumdisplay&fid='.$forum['fid'];}-->
					<!--{if empty($gid)}-->
						<span>
							<a href="$forumurl" class="forumname" {if $forum[redirect]} target="_blank"{/if}{if $forum[extra][namecolor]} style="color: {$forum[extra][namecolor]};"{/if}>$forum[name]<!--{if $forum['redirect']}--> *<!--{/if}--></a> <!--{if $forum[todayposts] && !$forum['redirect']}--><em class="xw0 xi1" title="{lang forum_todayposts}">$forum[todayposts]</em><!--{/if}-->
						</span>
						<span>
							<!--{if $forum['subforums']}--><!--{eval $forum['subforums'] = str_replace(",","",$forum['subforums'])}-->$forum['subforums']<!--{/if}-->
							<!--{hook/index_forum_extra $forum[fid]}-->
						</span>
					<!--{else}-->
						<!--{if $forum['orderid'] && ($forum['orderid'] % 2 == 0)}-->
							</tr>
							<!--{if $forum['orderid'] < $cat['forumscount']}-->
								<tr class="fl_row">
							<!--{/if}-->
						<!--{/if}-->
						<td class="fl_g">
							<div class="fl_icn_g"{if !empty($forum[extra][iconwidth]) && !empty($forum[icon])} style="width: {$forum[extra][iconwidth]}px;"{/if}>
							<!--{if $forum[icon]}-->
								$forum[icon]
							<!--{else}-->
								<a href="$forumurl"{if $forum[redirect]} target="_blank"{/if}><img src="{IMGDIR}/forum{if $forum[folder]}_new{/if}.gif" alt="$forum[name]" /></a>
							<!--{/if}-->
							</div>
							<dl{if !empty($forum[extra][iconwidth]) && !empty($forum[icon])} style="margin-left: {$forum[extra][iconwidth]}px;"{/if}>
								<dt><a href="$forumurl"{if $forum[redirect]} target="_blank"{/if}{if $forum[extra][namecolor]} style="color: {$forum[extra][namecolor]};"{/if}>$forum[name]</a><!--{if $forum[todayposts] && !$forum['redirect']}--><em class="xw0 xi1" title="{lang forum_todayposts}" style="margin-left:5px;">$forum[todayposts]</em><!--{/if}--></dt>
								<!--{if empty($forum[redirect])}--><dd><em>{lang forum_threads}: <!--{echo dnumber($forum[threads])}--></em>, <em>{lang forum_posts}: <!--{echo dnumber($forum[posts])}--></em></dd><!--{/if}-->
								<!--{hook/index_forum_extra $forum[fid]}-->
							</dl>
						</td>
					<!--{/if}-->
					<!--{/loop}-->
					$cat['endrows']
					<!--{if !empty($gid)}-->
						</tr>
					</table>
					<!--{/if}-->
				</div>
			</div>
			<!--{ad/intercat/bm a_c/$cat[fid]}-->
		<!--{/loop}-->
			<!--{if !empty($collectiondata['data'])}-->

			<!--{eval $forumscount = count($collectiondata['data']);}-->
			<!--{eval $forumcolumns = 4;}-->

			<!--{eval $forumcolwidth = (floor(100 / $forumcolumns) - 0.1).'%';}-->

			<div class="bm bmw {if $forumcolumns} flg{/if} cl">
				<div class="bm_h cl">
					<h2><a href="forum.php?mod=collection">{lang recommend_collection}</a></h2>
				</div>
				<div id="category_-2" class="bm_c" style="{echo $collapse['category_-2']}">
					<table cellspacing="0" cellpadding="0" class="fl_tb">
						<tr>
						<!--{eval $ctorderid = 0;}-->
						<!--{loop $collectiondata['data'] $key $colletion}-->
							<!--{if $ctorderid && ($ctorderid % $forumcolumns == 0)}-->
								</tr>
								<!--{if $ctorderid < $forumscount}-->
									<tr class="fl_row">
								<!--{/if}-->
							<!--{/if}-->
							<td class="fl_g"{if $forumcolwidth} width="$forumcolwidth"{/if}>
								<div class="fl_icn_g">
								<a href="forum.php?mod=collection&action=view&ctid={$colletion[ctid]}" target="_blank"><img src="{IMGDIR}/forum.gif" alt="$colletion[name]" /></a>
								</div>
								<dl>
									<dt><a href="forum.php?mod=collection&action=view&ctid={$colletion[ctid]}">$colletion[name]</a></dt>
									<dd><em>{lang forum_threads}: <!--{echo dnumber($colletion[threadnum])}--></em>, <em>{lang collection_commentnum}: <!--{echo dnumber($colletion[commentnum])}--></em></dd>
									<dd>
									<!--{if $colletion['lastpost']}-->
										<!--{if $forumcolumns < 3}-->
											<a href="forum.php?mod=redirect&tid=$colletion[lastpost]&goto=lastpost#lastpost" class="xi2"><!--{echo cutstr($colletion[lastsubject], 30)}--></a> <cite><!--{date($colletion[lastposttime])}--> <!--{if $colletion['lastposter']}-->$colletion['lastposter']<!--{else}-->$_G[setting][anonymoustext]<!--{/if}--></cite>
										<!--{else}-->
											<a href="forum.php?mod=redirect&tid=$colletion[lastpost]&goto=lastpost#lastpost">{lang forum_lastpost}: <!--{date($colletion[lastposttime])}--></a>
										<!--{/if}-->
									<!--{else}-->
										{lang never}
									<!--{/if}-->
									</dd>
									<!--{hook/index_datacollection_extra $colletion[ctid]}-->
								</dl>
							</td>
							<!--{eval $ctorderid++;}-->

						<!--{/loop}-->
						<!--{if ($columnspad = $ctorderid % $forumcolumns) > 0}--><!--{echo str_repeat('<td class="fl_g"'.($forumcolwidth ? " width=\"$forumcolwidth\"" : '').'></td>', $forumcolumns - $columnspad);}--><!--{/if}-->
						</tr>
					</table>

				</div>
			</div>

			<!--{/if}-->

		</div>
		<!--{if !empty($gid) && !empty($_G['setting']['grid']['showgrid'])}-->
			<!-- index four grid -->
			<div class="n_topic_b">
				<div class="cl">
					<div class="frame-title title"><span class="titletext">{$_G['style']['n_topic_b_title']}</span></div>
					<div class="n_topic_large">
						<ul>
							<!--{eval $tttttttt = C::t('forum_thread')->fetch_all_for_guide('newthread', 0, array(), 0, 0, 0, 30, $cat[forums])}-->
							<!--{loop $tttttttt $thread}-->
								<!--{if !$thread['forumstick'] && $thread['closed'] > 1 && ($thread['isgroup'] == 1 || $thread['fid'] != $_G['fid'])}-->
									<!--{eval $thread[tid]=$thread[closed];}-->
								<!--{/if}-->
							<li>
								<dl class="cl">
									<dd class="m"><a href="home.php?mod=space&uid=$thread[authorid]"{if $_G['setting']['grid']['targetblank']} target="_blank"{/if}><!--{avatar($thread[authorid],small)}--></a></dd>
									<dt><a href="forum.php?mod=viewthread&tid=$thread[tid]&extra=$extra"{if $thread['highlight']} $thread['highlight']{/if}title="$thread[subject]"{if $_G['setting']['grid']['targetblank']} target="_blank"{/if} class="_title">$thread[subject]</a></dt>
									<dd class="author"><a href="forum.php?mod=forumdisplay&fid=$thread[fid]"{if $_G['setting']['grid']['targetblank']} target="_blank"{/if} class="forumurl">{if $forumlist[$thread[fid]][name] && $thread['isgroup'] !== 1}$forumlist[$thread[fid]][name]{else}<!--{eval $tmp_group = C::t('forum_forum')->fetch_all_name_by_fid($thread['fid']);}-->$tmp_group[$thread[fid]][name]{/if}</a><a href="home.php?mod=space&uid=$thread[authorid]"{if $_G['setting']['grid']['targetblank']} target="_blank"{/if}><em class="author">$thread[author]</em></a> <em class="dateline"><!--{eval $dateline = str_replace('"', '\'', dgmdate($thread[dateline], 'u', '9999', getglobal('setting/dateformat')));}-->$dateline</em><em class="lastposter">{$_G['style']['n_topic_b_lastposter']}</em><a href="home.php?mod=space&username=$thread[lastposter]"{if $_G['setting']['grid']['targetblank']} target="_blank"{/if}>$thread[lastposter]</a>{if $thread[replies]}<em class="replies">$thread[replies]</em>{/if}</dd>
								</dl>
							</li>
							<!--{/loop}-->
						</ul>
					</div>
				</div>
			</div>
			<!-- index four grid end -->
			<!--{/if}-->

		<!--{hook/index_middle}-->

		<!--{hook/index_bottom}-->
	</div>

	<div class="sd" style="width: 305px; float: right;">
		<!--{hook/index_side_top}-->
		<div class="">
		</div>
		<div class="drag">
			<!--[diy=diy2]--><div id="diy2" class="area"></div><!--[/diy]-->
		</div>
		<!--{hook/index_side_bottom}-->

		<!--{if empty($gid)}-->
		<div class="p_stat">
			<p>
				{lang index_members}: <em>$_G['cache']['userstats']['totalmembers']</em> {lang index_posts}: <em>$posts</em>
			</p>
			<p>
				<!--{if $membercount}-->
					<a href="home.php?mod=space&do=friend&view=online&type=member">$onlinenum {lang onlines}</a>
				<!--{else}-->
					<strong>$onlinenum</strong> {lang onlines}
				<!--{/if}-->
				{lang index_mostonlines} $onlineinfo[0]
			</p>
		</div>
		<!--{/if}-->
	</div>
</div>
<!--{if $_G['group']['radminid'] == 1}-->
	<!--{eval helper_manyou::checkupdate();}-->
<!--{/if}-->
<!--{if empty($_G['setting']['disfixednv_forumindex']) }--><script>fixed_top_nv();</script><!--{/if}-->

<!--{if $_G['basescript'] == 'forum' && CURMODULE == 'index'}-->
	</div>
	</div>
	</div>
	<div id="bd_bottom"></div>

	<!--{if empty($gid) && ($_G['cache']['forumlinks'][0] || $_G['cache']['forumlinks'][1] || $_G['cache']['forumlinks'][2])}-->
			<div class="wp lk" style="width:995px;">
				<div id="category_lk" class="bm_c ptm">
					<!--{if $_G['cache']['forumlinks'][0]}-->
						<ul class="m mbn cl">$_G['cache']['forumlinks'][0]</ul>
					<!--{/if}-->
					<!--{if $_G['cache']['forumlinks'][1]}-->
						<div class="mbn cl">
							$_G['cache']['forumlinks'][1]
						</div>
					<!--{/if}-->
					<!--{if $_G['cache']['forumlinks'][2]}-->
						<ul class="x mbm cl">
							$_G['cache']['forumlinks'][2]
						</ul>
					<!--{/if}-->
				</div>
			</div>
		<!--{/if}-->

<!--{/if}-->


<!--{template common/footer}-->


